/**
 * 案例模块
 */

 define(function (require) {
    var $ = require('jquery');
    var base = require('base');
    var com = require('./common');

	if(localStorage.getItem("lang")){
		var Lang = localStorage.getItem("lang")
	}else{
		var Lang = "zh_CN"
	}

	// 中文/英文转换
	if(Lang != "zh_CN"){
		$('#zxns_banner_text').html("Recruitment Center")


	}




    // 第六部分
    // var swiper06 = new Swiper('.staff-swiper .swiper-container', {
    //     slidesPerView: 3,
    //     spaceBetween: 30,
    //     centeredSlides: true,
    //     loop: true,
    //     observer: true,//修改swiper自己或子元素时，自动初始化swiper
    //     observeParents: true,//修改swiper的父元素时，自动初始化swiper
    //     pagination: {
    //         el: '.swiper-pagination',
    //         clickable: true,
    //     },
    //     navigation: {
    //         nextEl: '.swiper-button-next',
    //         prevEl: '.swiper-button-prev',
    //     },
    //     breakpoints: {
    //         320: {  //当屏幕宽度大于等于320
    //             slidesPerView: 1,
    //             spaceBetween: 0
    //         },
    //         760: {  //当屏幕宽度大于等于768 
    //             slidesPerView: 2,
    //             spaceBetween: 20
    //         },
    //         1280: {  //当屏幕宽度大于等于1280
    //             slidesPerView: 3,
    //             spaceBetween: 30
    //         }
    //     }
    // });



    // if (/Android|webOS|iPhone|iPod|BlackBerry/i.test(navigator.userAgent)) {
	// 	var swiper = new Swiper('.swiper-container', {
	// 	  loop: true,
	// 	  slidesPerView: 1,
	// 	  pagination: {
	// 		el: '.swiper-pagination',
	// 	  },
	// 	})
	//   } else {
		var swiper = new Swiper('.swiper-container', {
		  autoplay: {
			delay: 5000,
			disableOnInteraction: false,
		  },
		  speed: 700,
		  allowTouchMove: false,
		  lazy: {
			loadPrevNext: true,
			loadPrevNextAmount: 3,
		  },
		  centeredSlides: true,
		  spaceBetween: 50,
		  slidesOffsetBefore: 40,
		  loop: true,
		  slidesPerView: 'auto',
		  on: {
			slideChangeTransitionEnd: function () {
			  this.slides.transition(this.params.autoplay.delay + this.params.speed).transform('translate3d(-60px, 0, 0)');
			},
			slideChangeTransitionStart: function () {
			  this.slides.transition(this.params.speed).transform('translate3d(0, 0, 0)');
			},
		  },
		  pagination: {
			el: '.swiper-pagination',
			clickable: true,
			renderBullet: function (index, className) {
			  return '<div class="' + className + '"><span></span><i></i></div>';
			},
		  },
		  navigation: {
			nextEl: '.swiper-button-next',
			prevEl: '.swiper-button-prev',
		  },
		});

		console.log("swiper:", swiper)

		// window.onresize = function () {
		//   swiper.update();
		// }
  
	//   }



 })
